﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Studio77.SuperLink.Core;

namespace Studio77.ForestSounds
{
    public class DataManager
    {
        public static DataManager Instance = new DataManager();

        private DataManager()
        {
            //初始化数据
            int i = 0;

            animalInfos = new List<AnimalInfo>();
            //狗熊
            SoundManager.PreLoadSound(++i, "Sounds/bear.wav");
            SoundManager.PreLoadSound(++i, "Sounds/bear_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/bear_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "狗熊",
                EnName = "Bear",
                ImageName = "bear_light.png",
                SoundName = "bear",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //野鸡
            SoundManager.PreLoadSound(++i, "Sounds/pheasant.wav");
            SoundManager.PreLoadSound(++i, "Sounds/pheasant_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/pheasant_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "野鸡",
                EnName = "Pheasant",
                ImageName = "pheasant_light.png",
                SoundName = "pheasant",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //老虎
            SoundManager.PreLoadSound(++i, "Sounds/tiger.wav");
            SoundManager.PreLoadSound(++i, "Sounds/tiger_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/tiger_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "老虎",
                EnName = "Tiger",
                ImageName = "tiger_light.png",
                SoundName = "tiger",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //孔雀
            SoundManager.PreLoadSound(++i, "Sounds/peacock.wav");
            SoundManager.PreLoadSound(++i, "Sounds/peacock_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/peacock_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "孔雀",
                EnName = "Peacock",
                ImageName = "peacock_light.png",
                SoundName = "peacock",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //松鼠
            SoundManager.PreLoadSound(++i, "Sounds/squirrel.wav");
            SoundManager.PreLoadSound(++i, "Sounds/squirrel_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/squirrel_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "松鼠",
                EnName = "Squirrel",
                ImageName = "squirrel_light.png",
                SoundName = "squirrel",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //猩猩
            SoundManager.PreLoadSound(++i, "Sounds/gorilla.wav");
            SoundManager.PreLoadSound(++i, "Sounds/gorilla_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/gorilla_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "猩猩",
                EnName = "Gorilla",
                ImageName = "gorilla_light.png",
                SoundName = "gorilla",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //猴子
            SoundManager.PreLoadSound(++i, "Sounds/monkey.wav");
            SoundManager.PreLoadSound(++i, "Sounds/monkey_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/monkey_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "猴子",
                EnName = "Monkey",
                ImageName = "monkey_light.png",
                SoundName = "monkey",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //鹿
            SoundManager.PreLoadSound(++i, "Sounds/deer.wav");
            SoundManager.PreLoadSound(++i, "Sounds/deer_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/deer_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "鹿",
                EnName = "Deer",
                ImageName = "deer_light.png",
                SoundName = "deer",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
            //野猪
            SoundManager.PreLoadSound(++i, "Sounds/wildboar.wav");
            SoundManager.PreLoadSound(++i, "Sounds/wildboar_cn.wav");
            SoundManager.PreLoadSound(++i, "Sounds/wildboar_us.wav");
            animalInfos.Add(new AnimalInfo()
            {
                CnName = "野猪",
                EnName = "Wildboar",
                ImageName = "boar_light.png",
                SoundName = "wildboar",
                AnimalSoundId = i - 2,
                CnSoundId = i - 1,
                EnSoundId = i
            });
        }
        public List<AnimalInfo> animalInfos { get; set; }


    }


    public class AnimalInfo
    {
        public string CnName { get; set; }

        public string EnName { get; set; }

        public string ImageName { get; set; }

        public string SoundName { get; set; }

        public int CnSoundId { get; set; }
        public int EnSoundId { get; set; }
        public int AnimalSoundId { get; set; }
    }
}
